package com.sky.controller.user;

import com.sky.entity.Dish;
import com.sky.result.Result;
import com.sky.service.user.DishService;
import com.sky.vo.DishVO;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

/**
 * @author cgj
 * @Description
 * @create 2025-10-31 下午9:06
 */
@RestController("userDishController")
@RequestMapping("/user/dish")
@Slf4j
public class DishController {

    @Autowired
    private DishService dishService;

    public Result<List<DishVO>> dishController(@RequestParam Integer categoryId) {
        log.info("用户端查询菜品中，该菜品所属的分类为：{}", categoryId);
        dishService.ListDish(categoryId);

        //todo 返回dishvo类
        return null;
    }
}
